
package com.feib.ebilling.job.util;

import java.util.Collections;
import java.util.Enumeration;
import java.util.Properties;
import java.util.Vector;



/**
 * @title (#)SortedProperties.java<br>
 * @description <br>
 * @author Jimmy Liu<br>
 * @version 1.0.0 2010/11/25
 * @copyright Far Eastern International Bank Copyright (c) 2010<br>
 * @2011/1/21 create by Jimmy Liu<br>
 */
public class SortedProperties extends Properties {

    private static final long serialVersionUID = 8725801013955091153L;
    
    /* (non-Javadoc)
     * @see java.util.Hashtable#keys()
     */
    @SuppressWarnings({ "unchecked", "rawtypes" })
    @Override
    public synchronized Enumeration keys() {
        Enumeration keysEnum = super.keys();
        Vector keyList = new Vector();
        while(keysEnum.hasMoreElements()){
          keyList.add(keysEnum.nextElement());
        }
        Collections.sort(keyList);
        return keyList.elements();
     }

}
